<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="common/include :: header('新增养修服务项')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <form class="form-horizontal m" id="form-employee-add">
        <div class="form-group">
            <label class="col-sm-3 control-label is-required">姓名：</label>
            <div class="col-sm-8">
                <input class="form-control" type="text" name="name" required>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label is-required">邮箱：</label>
            <div class="col-sm-8">
                <input class="form-control" type="text" name="email" required>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label is-required">年龄：</label>
            <div class="col-sm-8">
                <input class="form-control" type="number" name="age" required>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label is-required">是否超管：</label>
            <div class="col-sm-8">
                <div class="radio-box" th:each="items : ${@dict.getType('si_car_package')}">
                    <input type="radio" th:id="${items.id}" name="admin" th:value="${items.value}" th:checked="${items.isDefault}">
                    <label th:for="${items.id}" th:text="${items.label}"></label>
                </div>
            </div>
        </div>

        <div class="form-group">
            <label class="col-sm-3 control-label is-required">所在部门：</label>
            <div class="col-sm-8">
                <select name="deptId">
                <option value="">所有</option>
                <option th:each="item : ${departments}" th:text="${item.name}" th:value="${item.id}"></option>
                </select>
            </div>
        </div>
    </form>
</div>
<th:block th:include="common/include :: footer" />
<script type="text/javascript">
    var prefix = ctx + "/business/employee";

    function submitHandler() {
        if ($.validate.form()) {
            $.operate.save(prefix + "/add", $('#form-employee-add').serialize());
        }
    }
</script>
</body>
</html>
